doctype
html
	head
		meta(charset="utf-8")
		title #{title}
		link(rel="stylesheet" type="text/css" href="css/bootstrap.css")
		link(rel="stylesheet" type="text/css" href="css/main.css")
	body
		.top
			img(src="img/logo.png")
		.main
			.btnBox
				a(href="javascript:;" id="addLine") 增加
			div(id="list")
				table#lblResponse
					tr
						th 名称
						th 规格
						th 数量
						th 操作1
						th 操作2
					each item in data
							each x,i in item.property
								tr
									if i == 0
										td.txt_l(rowspan=item.property.length) #{item.name}
									td #{x.spec}
									if x.num == 0
										td <span class="red">#{x.num}</span>
									if x.num != 0
										td <span class="green">#{x.num}</span>
									td
										a(href="javascript:;" _name="delete" atr="+" dfname=item.name num=x.num id=x.id) +库存
										a(href="javascript:;" _name="delete" atr="-" dfname=item.name num=x.num id=x.id) -库存
										a(href="javascript:;" id="deleteLine" listId=x.id gid=x.gid) 删除
									if i == 0
										td(rowspan=item.property.length)
											a(href="javascript:;" _name="add1" dfname=item.name gid=x.gid) 增加规格
		.pip#pipAdd
			h2 操作信息
			form.form-horizontal(role="form" id="form1" method="post" action="http://localhost:3000/add")
				.form-group
					label.col-sm-2.control-label(for="name") 名称
					.col-sm-10
						input#name.form-control(type="text" name="name")
				.form-group
					label.col-sm-2.control-label(for="spec") 规格
					.col-sm-10
						input#spec.form-control(type="text" name="spec")
				.form-group
					label.col-sm-2.control-label(for="num") 数量
					.col-sm-10
						input#num.form-control(type="text" name="num")
				.form-group
					.col-sm-offset-2.col-sm-10
						a.btn.btn-primary(href="javascript:;" id="add") 确认添加
						a.btn.btn-default.closeWin(href="javascript:;" id="close") 关闭
		.pip#pipDelete
			h2 减少库存
			form.form-horizontal(id="form2" method="post" action="http://localhost:3000/atrData")
				p.delText <span></span>的数量还有<em>4</em>条，请输入你要<i>减少</i>的库存数量
				.form-group
					label.col-sm-2.control-label(for="num2") 数量
					.col-sm-8
						input#num2.form-control(type="text" name="num2")
				.form-group
					.col-sm-offset-2.col-sm-10
						a.btn.btn-primary(href="javascript:;" id="deleteIt") 提交
						a.btn.btn-default.closeWin(href="javascript:;" id="close2") 关闭
	script(type="text/javascript" src="js/jquery.js")
	script(type="text/javascript" src="js/bootstrap.js")
	script(type="text/javascript" src="js/main.js")
